import java.util.*;


public class InstructionSet {
	HashMap<String, String> instructionSet = new HashMap<String, String>();
	public InstructionSet() {
		
		instructionSet.put("jmp", "00001");
		
		instructionSet.put("ld", "00010");
		instructionSet.put("st", "00011");
		
		instructionSet.put("add", "00100");
		instructionSet.put("sub", "00101");
		
		instructionSet.put("sll", "00110");
		instructionSet.put("srl", "00111");
		
		instructionSet.put("and", "01000");
		instructionSet.put("or", "01001");
		instructionSet.put("nor", "01010");
		instructionSet.put("xnor", "01011");
		
		instructionSet.put("ba", "01100");
		instructionSet.put("bne", "01101");
		instructionSet.put("be", "01110");
		instructionSet.put("bg", "01111");
		instructionSet.put("bge", "10000");
		instructionSet.put("bl", "10001");
		instructionSet.put("ble", "10010");
		
		instructionSet.put("in", "10011");
		instructionSet.put("out", "10100");
		
		instructionSet.put("halt", "10101");
		instructionSet.put("swap", "10110");

		instructionSet.put("mov", "10111");
		instructionSet.put("?1", "11000");
		instructionSet.put("?2", "11001");
		instructionSet.put("?3", "11010");
		instructionSet.put("?4", "11011");
	}
	
	public String getOpCode(String instruc) {
		return instructionSet.get(instruc);
	}
}
